const Mock = require('mockjs')
const userList = Mock.mock({
  'data|3': [
    {
      cname: '@cname',
      name: '@first @last',
      avatar: '@image(125x125)',
      'id|+1': 1,
    },
  ],
})

module.exports = [
  {
    method: 'post',
    url: '/api/users',
    response: ({ body }) => {
      // body -> 请求体
      console.log('body', body)
      return {
        status: 1,
        ...userList,
      }
    },
  },
]
